// ignore_for_file: file_names
import 'package:flutter/material.dart';

class PageViewPage extends StatefulWidget {
  const PageViewPage({super.key});

  @override
  State<PageViewPage> createState() => _PageViewPageState();
}

class _PageViewPageState extends State<PageViewPage> {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(title: const Text("PageviewPage")),
      body: PageView(
        scrollDirection: Axis.vertical, // 配置 PageView 滑动方向，默认是水平方向
        children: [
          Center(
            child: Text(
              "第01屏",
              style: Theme.of(context).textTheme.headline1,
            ),
          ),
          Center(
            child: Text(
              "第02屏",
              style: Theme.of(context).textTheme.headline1,
            ),
          ),
          Center(
            child: Text(
              "第03屏",
              style: Theme.of(context).textTheme.headline1,
            ),
          ),
          Center(
            child: Text(
              "第04屏",
              style: Theme.of(context).textTheme.headline1,
            ),
          ),
          Center(
            child: Text(
              "第05屏",
              style: Theme.of(context).textTheme.headline1,
            ),
          ),
          Center(
            child: Text(
              "第06屏",
              style: Theme.of(context).textTheme.headline1,
            ),
          ),
          Center(
            child: Text(
              "第07屏",
              style: Theme.of(context).textTheme.headline1,
            ),
          ),
        ],
      ),
    );
  }
}
